#include <bits/stdc++.h>
#define sc(x) scanf("%lld", &(x))
#define pr(x) printf("%lld\n", (x))
#define rep(i, l, r) for (int i = l; i <= r; ++i)
using namespace std;
typedef long long ll;
const int N = 1e5 + 7;
const int mod = 1e9 + 7;
vector<int> G[N];
int n;
long double p, r;
int d = INT_MAX;
int cnt = 0;
void dfs(int fa, int dep) {
    if (G[fa].empty()) {
        if (dep < d) d = dep, cnt = 0;
        if (dep == d) ++cnt;
    }
    for (int x : G[fa]) dfs(x, dep + 1);
}
int main() {
    cin >> n >> p >> r;
    r = (1 + 0.01 * r);
    for (int i = 0, len, x; i < n; ++i) {
        cin >> len;
        rep(_, 1, len) {
            cin >> x;
            G[i].push_back(x);
        }
    }
    dfs(0, 0);
    cout << fixed << setprecision(4) << p * pow(r, d) << ' ' << cnt << '\n';
    return 0;
}